package unit01;

/**
 * @author wangzhuangzhuang
 * @DESC: Runnable接口的匿名内部类实现
 * @date 2022-05-02 22:17
 */
public class RunnableDemo {

	public static void main(String[] args) {
		Runnable r = () -> System.out.println("lambda expression implementing the run method.");
		new Thread(r).start();
		System.out.println("==================================================");
		new Thread(new Runnable(){
			@Override
			public void run() {
				System.out.println("inside runnable using an anonymous inner class");
			}
		}).start();
	}

}